<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        html,
        body,
        ul {
            margin: 0;
            padding: 0;
            overflow: hidden;
            zoom: 1;
        }

        html,
        body {
            height: 100%;
            font: 12px/1.5 Tahoma;
        }

        #tab,
        #div1 {
            border: 1px solid black;
            width: 500px;
            margin: 0 auto;
        }

        #tab {
            border-bottom: 0;
            background: black;
            color: white;
        }

        #tab li {
            width: 60px;
            float: left;
            list-style-type: none;
            line-height: 30px;
            text-align: center;
            padding: 0 10px;
            cursor: pointer;
        }

        #tab li.current {
            background: white;
            color: black;
        }

        /*内容区的样式*/

        #div1 ul {
            padding: 10px 0 0 30px;
            display: none;
            line-height: 25px;
        }

    </style>
</head>
<body>
       <ul id="tab">
           <li  class="current">第1节课</li><li>第2节课</li><li>第3节课</li>
       </ul>
       <div id="div1">
        <ul style="display:block;">
            <li>顺利打开开发</li>
            <li>顺利打开开发</li>
            <li>顺利打开开发</li>
            <li>顺利打开开发</li>
            <li>顺利打开开发</li>
         </ul>
         <ul>
             <li>大手大脚空间</li>
             <li>大手大脚空间</li>
             <li>大手大脚空间</li>
             <li>大手大脚空间</li>
             <li>大手大脚空间</li>
          </ul>
          <ul>
             <li>发生的回复就会受到</li>
             <li>发生的回复就会受到</li>
             <li>发生的回复就会受到</li>
             <li>发生的回复就会受到</li>
             <li>发生的回复就会受到</li>
          </ul>
       </div>
      <script>
         window.onload = function() {
            var bba = document.getElementById("tab").getElementsByTagName("li");
            var bwm = document.getElementById("div1").getElementsByTagName("ul");
            for (var i = 0; i < bba.length; i++) {
                bba[i].index = i; 
                bba[i].onmouseover = function() {
                    for (var n = 0; n < bba.length; n++) bba[n].className = ""; 
                    this.className = "current";
                    for (var n = 0; n < bwm.length; n++) bwm[n].style.display = "none";
                    bwm[this.index].style.display = "block";
                }
            }
        }
      </script>
</body>
</html>